home *** CD-ROM | disk | FTP | other *** search
- Path: news.cern.ch!danpop
- From: danpop@mail.cern.ch (Dan Pop)
- Newsgroups: comp.lang.c
- Subject: Re: May fprintf () be recursive?
- Date: 18 Apr 96 17:46:49 GMT
- Organization: CERN European Lab for Particle Physics
- Message-ID: <danpop.829849609@news.cern.ch>
- References: <4l5f9s$ad3@news.cs.tu-berlin.de> <4l5pdi$d8q@news.cs.tu-berlin.de>
- NNTP-Posting-Host: ues5.cern.ch
- Mime-Version: 1.0
- Content-Type: text/plain; charset=US-ASCII
- Content-Transfer-Encoding: 7bit
- X-Newsreader: NN version 6.5.0 #18 (NOV)
-
- In <4l5pdi$d8q@news.cs.tu-berlin.de> ulrich@cs.tu-berlin.de (Ulrich Wittenberg) writes:
-
-
- >As was pointed out to me, it's not a recursion, but a nested/reentrant
- >call of fprintf, that seems to wreak havoc.
-
- It's _not_ nested and it's _not_ reentrant. There are two independent
- fprintf calls, the only connection between them being that the outer one
- uses the value returned by the inner one as argument. There is even a
- sequence point between the return of the inner fprintf and the invocation
- of the outer fprintf.
-
- >The question remains: Is
- >is legal to call fprintf from within another fprintf?
-
- The answer remains: Yes, it's perfectly legal.
-
- Dan
- --
- Dan Pop
- CERN, CN Division
- Email: danpop@mail.cern.ch
- Mail: CERN - PPE, Bat. 31 R-004, CH-1211 Geneve 23, Switzerland
-